//
//  WTBaseService.m
//  WTLiveSDKDemo
//
//  Created by ben on 16/10/1.
//  Copyright © 2016年 ben. All rights reserved.
//

#import "WTBaseService.h"
#import "WTLiveSDKHeaders.h"
#import "NSString+WTLive.h"


@implementation WTBaseService

+ (void)load{
    
    [HYBNetworking updateBaseUrl:@"http://123.56.184.48:83"];
    
//    [HYBNetworking updateBaseUrl:@"http://192.168.31.101:1333"];
    
//    [HYBNetworking updateBaseUrl:@"http://192.168.31.102:1333"];
    
    [HYBNetworking cacheGetRequest:YES shoulCachePost:YES];
    [HYBNetworking obtainDataFromLocalWhenNetworkUnconnected:YES];
}

- (NSString*)encode{
    return [NSString encryptUseDES:[self.param mj_JSONString] key:WTConfig.desKey];
}

-(void)start:(NSDictionary *)param completionHandler:(WTServiceCompletionHandler)completionHandler{
 
    [self cancle];
}

- (void)cancle {
     [HYBNetworking cancelRequestWithURL:self.subPath];
}
@end
